package sopraim.entity;
/**
 * User status (available, busy, disconnected, absent)
 * @author INFO-A1
 */
public class Status {
    
    private int id;
    private String name ;
    
    public Status() {
    }
    
    public Status(String n){
        String[] status_names =
        {"available", "busy", "absent","offline"};
       for(int i=0;i<status_names.length;i++){
           if(n.equals(status_names[i])){
               this.name = n;
               this.id = i;
           }
       }
}
/**
 * @return the id
 */
public int getId() {
return id;
}

/**
 * @param id the id to set
 */
public void setId(int id) {
this.id = id;
}
/**
 * @return the name
 */
public String getName() {
return name;
}
/**
 * @param name the name to set
 */
public void setName(String name) {
this.name = name;
}

}